package com.example.demo.service.impl;


import com.example.demo.entity.ShopCart;
import com.example.demo.entity.ShopCartInformation;
import com.example.demo.mapper.ShopCartMapper;
import com.example.demo.service.ShopCartService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class ShopCartServiceImpl implements ShopCartService {
    @Autowired
    ShopCartMapper shopCartMapper;


    @Override
    public Integer ShopAddProduct(ShopCartInformation shopCartInformation) {
        return shopCartMapper.ShopAddProduct(shopCartInformation);
    }

    @Override
    public ShopCart UserShopCartId(Integer cartUserId) {
        return shopCartMapper.UserShopCartId(cartUserId);
    }

    @Override
    public Integer InSertUserCartId(Integer cartUserId) {
        return shopCartMapper.InSertUserCartId(cartUserId);
    }

    @Override
    public ShopCartInformation SelectShopItem(Integer itemUserId, Integer itemSkuId) {
        return shopCartMapper.SelectShopItem(itemUserId,itemSkuId);
    }

    @Override
    public Integer AddUserProductCount(ShopCartInformation shopCartInformation) {
        return shopCartMapper.AddUserProductCount(shopCartInformation);
    }

}
